package service.contains;

import relations.Associate;
import relations.belongsTo;
import relations.contains;
import dao.AlbumDAO;
import dao.AssociateDAO;
import dao.RecordDuplicateException;
import dao.belongsToDAO;
import dao.containsDAO;
import entities.Customer;
import entities.User;
import entities.Album;
import entities.Order;



public class containsServiceInMemory implements containsService {

	public containsServiceInMemory(){
		
	}
	
	public static containsService newInstance(){
		return new containsServiceInMemory();
	}
	
	/**
	 * Finds a Album based on the Album id.
	 * @param userid - user id
	 * @return the instance of the Album
	 */
	
	public contains findContains(Long product_id, String orderID, float price, int qty) {
		containsDAO db =  containsDAO.getInstance();
		contains result = null;
		result = db.findContains(product_id, orderID, price, qty);
		return result;
		

	}
	
	
	/**
	 * Adds a new Album to the system.
	 * @param obj - the Album instance to add
	 */
	
	public void addContains(contains obj) throws RecordDuplicateException{
		containsDAO db = containsDAO.getInstance();	
		db.addContains(obj);
		return;
	}











}
